package cn.com.qiter.eduorder.client;

import cn.com.qiter.common.Result;
import cn.com.qiter.common.ordervo.UcenterMemberOrder;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;

@Component
@FeignClient("service-ucenter")
public interface UcenterClient {

    //根据课程id和用户id查询订单表中订单状态
    @GetMapping("/educenter/qrcode/getOneByQrcode/{codeNumber}")
    public Result getByName(@PathVariable("codeNumber") String codeNumber);


    //根据课程id和用户id查询订单表中订单状态
    @GetMapping("/educenter/project/getOneDeleted/{id}")
    public Result getOneDeleted(@PathVariable("id") String id);


    //根据课程id和用户id查询订单表中订单状态
    @GetMapping("/educenter/project/getOne/{id}")
    public Result getProjectById(@PathVariable("id") String id);

    //根据用户id获取用户信息
    @PostMapping("/educenter/member/getUserInfoOrder/{id}")
    public UcenterMemberOrder getUserInfoOrder(@PathVariable("id") String id);
}
